from time import time
st=time()
with open ('m2_reverse.txt') as f:
    a=[]
    for line in f:
        a.append([int(x) for x in line.split()])

for i in range(len(a)):
    for j in range(lin(a)-i-1):
        if a[j] > a[j+1]:
            a[j], a[j+1], a[j]

print(a)
fi = time()
t= fi - st
print(t)
